﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;

public partial class Admin_AdminViewEmployeeInfor : System.Web.UI.Page
{
    AddminMethord AM = new AddminMethord();
    string User = "";
    protected void Page_Load(object sender, EventArgs e)
    {
        try
        {
            User = Request.QueryString["ID"].ToString();
            LoadData();
        }
        catch (Exception ex)
        {
        }
    }
    public void LoadData()
    {
        DataTable tb = AM.LoadDataEmployee(User);
        foreach (DataRow item in tb.Rows)
        {
            txtHRID.Text = item["UserName"].ToString();
            txtName.Text = item["FullName"].ToString();
            txtAddress.Text = item["Address"].ToString();
            txtPhone.Text = item["Phone"].ToString();
            txtBirthOfDate.Text = item["BirthOfDate"].ToString().Substring(0, item["BirthOfDate"].ToString().IndexOf(" "));
            txtEmailID.Text = item["EmailID"].ToString();
            lbtnResetpassword.PostBackUrl = "ResetPassword.aspx?HRID=" + item["UserName"].ToString();
        }
    }
}